/*
 * @Descripttion: 
 * @Author: voanit
 * @Date: 2022-05-18 11:17:10
 * @LastEditors: voanit
 * @LastEditTime: 2022-05-19 08:35:37
 */
import React from 'react'
import {Select}  from  'antd'
import { useChannels } from '@/hooks/useChannels'
const Channel = (props) => {
  const channels = useChannels()
  // console.log(props,99881);
  return (
    <Select
      {...props}
      style={{ width: 200 }}
      allowClear
      placeholder="请选择频道"
    >
       <Select.Option></Select.Option>
      {channels.map((item) => (
        <Select.Option value={item.id} key={item.id}>
          {item.name}
        </Select.Option>
      ))}
    </Select>
  )

};
export default Channel